<form id="pagerForm" action="__URL__" method="post">   <!-- action="#rel#" -->
    <input type="hidden" name="p" value="1" />
    <input type="hidden" name="numPerPage" value="{$numPerPage}" />
    <input type="hidden" name="orderField" value="{$orderField}" />
    <input type="hidden" name="orderDirection" value="{$param.orderDirection}" />
</form>
<div class="pageContent">
    <div class="panelBar">
        <ul class="toolBar">
            <if condition="in_array('insert', $privilegelist)">
                <li><a class="add" href="__URL__/add" rel="adminadd"  target="dialog"><span>添加</span></a></li>
                <li class="line">line</li>
            </if>
            <if condition="in_array('delete', $privilegelist)">
                <li><a title="确实要删除这些记录吗?" target="selectedTodo" rel="ids" href="__URL__/delAll" postType="string" class="delete"><span>批量删除</span></a></li>
                <li class="line">line</li>
            </if>
        </ul>
    </div>
    
    <table class="table" width="100%" layoutH="74">
        <thead>
            <tr>
            <if condition="in_array('delete', $privilegelist)">
                <th>
                    <input type="checkbox" group="ids" class="checkboxCtrl" />
                </th>
            </if>
            <th>积分类型</th>
            <th>奖励积分</th>
            <th>开始日期</th>
            <th>结束日期</th>
            <th>状态</th>
            <th>操作</th>
            </tr>
        </thead>
        <tbody>
        <volist name="list" id="vo">
            <tr rel="{$vo.id}" target="id">
                <if condition="in_array('delete', $privilegelist)">
                    <td>
                        <input name="ids" value="{$vo.id}" type="checkbox"/>
                    </td>
                </if>
                <td>{$vo.typeName}</td>
                <td>{$vo.score}</td>
                <td>{$vo.startTime|date="Y-m-d H:i:s",###}</td>
                <td>{$vo.endTime|date="Y-m-d H:i:s",###}</td>
                <switch name="vo.status">
                    <case value="0">
                    <td>正常</td>
                    </case>
                    <case value="1">
                    <td>下架</td>
                    </case>
                </switch>
                <td>
                    <if condition="$vo.status eq 0">
                        <a title="是否要停用积分规则?" target="ajaxTodo" href="__URL__/update_status/id/{$vo.id}" style="float:left;">停用</a>
                    <else />
                        <a title="是否要启用积分规则?" target="ajaxTodo" href="__URL__/update_status/id/{$vo.id}" style="float:left;">启用</a>
                    </if>
                    <if condition="in_array('edit', $privilegelist)">
                        <a title="编辑" target="dialog" href="__URL__/edit/id/{$vo.id}" class="btnEdit"  rel="adminedit">编辑</a>
                    </if>
                    <if condition="in_array('delete', $privilegelist)">
                        <a title="是否要删除当前商品?" target="ajaxTodo" href="__URL__/delete/id/{$vo.id}"class="btnDel">删除</a>
                    </if>
                </td>
            </tr>
        </volist>
        </tbody>
    </table>
    <div class="panelBar">
        <div class="pages">
            <span>显示</span>
            <select class="combox" name="numPerPage" onchange="navTabPageBreak({numPerPage:this.value})">
                <option value="20" <?php echo $numPerPage == 20 ? 'selected="true"' : '' ; ?> >20</option>
                <option value="50" <?php echo $numPerPage == 50 ? 'selected="true"' : '' ; ?>>50</option>
                <option value="100" <?php echo $numPerPage == 100 ? 'selected="true"' : '' ; ?> >100</option>
                <option value="200" <?php echo $numPerPage == 200 ? 'selected="true"' : '' ; ?> >200</option>
            </select>
            <span>条，共{$totalCount}条</span>
        </div>

        <div class="pagination" targetType="navTab" totalCount="{$totalCount}" numPerPage="{$numPerPage}" pageNumShown="10" currentPage="{$currentPage}"></div>

    </div>
</div>
